package net.sf.jOpinionPoll.tag.component;

import javax.faces.component.UIComponent;
import javax.faces.webapp.UIComponentELTag;

/**
 * @author EricoGR
 *
 */
public class UserInformationTag extends UIComponentELTag {
	private String m_Info;
	private String m_StyleClass;
	private String m_Style;
	
	private static final String COMPONENT_TYPE = "net.sf.jOpinionPoll.tag.component.UserInformationTagComponent";
	private static final String RENDER_TYPE = "net.sf.jOpinionPoll.tag.component.UserInformationTagRenderer";
	
	public void setInfo(String info) {
		this.m_Info = info;
	}

	public String getInfo() {
		return m_Info;
	}
	
	public String getStyleClass() {
		return m_StyleClass;
	}

	public void setStyleClass(String styleClass) {
		this.m_StyleClass = styleClass;
	}

	public String getStyle() {
		return m_Style;
	}

	public void setStyle(String style) {
		this.m_Style = style;
	}

	@Override
	protected void setProperties(UIComponent component) {
		super.setProperties(component);
		((UIUserInformationComponent)component).setInfo(getInfo());
		((UIUserInformationComponent)component).setStyle(getStyle());
		((UIUserInformationComponent)component).setStyleClass(getStyleClass());
	}


	@Override
	public String getComponentType() {
		return COMPONENT_TYPE;
	}

	@Override
	public String getRendererType() {
		return RENDER_TYPE;
	}
}